//
//  BCJoinPeopleCollectionCell.m
//  GSBlockChain
//
//  Created by guoshikeji_a on 2018/11/22.
//  Copyright © 2018年 guoshikeji. All rights reserved.
//

#import "BCJoinPeopleCollectionCell.h"

@interface BCJoinPeopleCollectionCell ()

@property (nonatomic, strong) UIImageView *headIV;

@end

@implementation BCJoinPeopleCollectionCell

- (instancetype)initWithFrame:(CGRect)frame {
    self = [super initWithFrame:frame];
    if (self) {
        if (!_headIV) {
            self.headIV = [UIImageView new];
            self.headIV.layer.borderWidth = 1.0;
            self.headIV.layer.borderColor = [UIColor whiteColor].CGColor;
            self.headIV.layer.masksToBounds = true;
            self.headIV.backgroundColor = [UIColor separatorViewColor];
            [self addSubview:self.headIV];
            //
            [self.headIV mas_makeConstraints:^(MASConstraintMaker *make) {
                make.edges.mas_equalTo(self);
            }];
        }
    }
    return self;
}


- (void)setHead_img:(NSString *)head_img {
    _head_img = head_img;
    //
    [self.headIV sd_setImageWithURL:[NSURL URLWithString:head_img]];
}



- (void)layoutSubviews {
    [super layoutSubviews];
    self.headIV.layer.cornerRadius = self.frame.size.width/2;
}

@end
